Skip to content

chore(demo): remove prisma/seed.demo.ts (lives in vectorflow-demo-ops)#189

Merged
TerrifiedBug merged 1 commit intomainfrom
chore/revert-demo-seed
Apr 27, 2026
Merged

chore(demo): remove prisma/seed.demo.ts (lives in vectorflow-demo-ops)#189
TerrifiedBug merged 1 commit intomainfrom
chore/revert-demo-seed

Conversation

@TerrifiedBug
Copy link
Copy Markdown
Owner

Summary

Reverts the seed script added in #188. Demo seed data is an ops concern that already has a home: `vectorflow-demo-ops` owns the demo lifecycle via `scripts/seed.sql` + `scripts/nightly-reset.sh` + a 03:00 UTC cron entry that does `compose down -v` → migrate → `psql < seed.sql` → restart web.

Adding `prisma/seed.demo.ts` to this repo duplicated work that already lives where it belongs and put a destructive script (wipes the demo user and cascades) into the app codebase with no callers — the demo deployment doesn't use `pnpm seed:demo`, it uses `seed.sql` via psql.

Changes

  • Delete `prisma/seed.demo.ts` (-751 lines)
  • Drop `seed:demo` from `package.json` scripts

Follow-up

A separate PR against `vectorflow-demo-ops` will port the richer dataset that #188 was producing (3 environments, 12 nodes, 8 pipelines, 5-min `PipelineMetric` granularity, 14 anomaly events, 5 cost recommendations) into `seed.sql` so the demo deployment actually benefits from the work. Postgres `generate_series` handles the time-series synthesis natively, so the SQL form is a clean fit.

Test plan

  • `pnpm lint` -- 0 errors
  • `pnpm tsc --noEmit` -- clean
  • confirm no CI references the removed script

…emo-ops)

Demo seed data is an ops concern, not an app concern. The vectorflow-demo-ops
repo already owns the demo lifecycle: scripts/seed.sql + scripts/nightly-reset.sh
+ compose.yaml + a cron entry that does compose-down/up + migrate + psql-seed
+ restart-web on a 03:00 UTC schedule.

Adding prisma/seed.demo.ts to the app repo in #188 duplicated work that
already lives where it belongs and put a destructive script (rm + rebuild
all data scoped to the demo user) into the application repository where it
has no callers — the demo deployment uses seed.sql via psql, not the
seed:demo npm script.

This reverts #188's seed.demo.ts and the seed:demo package.json script.
A follow-up against vectorflow-demo-ops will port the richer dataset
(3 environments, 12 nodes, 8 pipelines, 5-min PipelineMetric granularity,
14 anomaly events, 5 cost recommendations) into seed.sql so the demo
deployment actually benefits from that work.
@github-actions github-actions Bot added ignore-for-release dependencies Pull requests that update a dependency file and removed ignore-for-release labels Apr 27, 2026
@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented Apr 27, 2026

Greptile Summary

This PR reverts prisma/seed.demo.ts and its seed:demo package script, which were added in #188. The demo seed logic belongs in vectorflow-demo-ops (already handled via seed.sql + nightly cron), so removing it from this repo is correct. No CI workflows reference the removed script.

Confidence Score: 5/5

Safe to merge — pure deletion with no callers or CI references affected.

Both changed files are a straightforward removal: a dead script file and its package.json entry. No CI workflows reference the deleted script, no other code imports or calls it, and the PR description correctly identifies that the demo lifecycle lives in a separate ops repo.

No files require special attention.

Important Files Changed

Filename Overview
package.json Removes the seed:demo script entry — clean, no dangling references remain
prisma/seed.demo.ts 751-line demo seed file deleted in full — no callers existed in this repo

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A["#188 added prisma/seed.demo.ts\n+ seed:demo script"] -->|"This PR (#189) reverts"| B["prisma/seed.demo.ts DELETED\nseed:demo removed from package.json"]
    B --> C["Demo seed data responsibility"]
    C --> D["vectorflow-demo-ops\nscripts/seed.sql\nscripts/nightly-reset.sh\n03:00 UTC cron"]
    style A fill:#f87171,color:#fff
    style B fill:#4ade80,color:#000
    style D fill:#60a5fa,color:#fff
Loading

Reviews (1): Last reviewed commit: "chore(demo): remove seed.demo.ts from ap..." | Re-trigger Greptile

@TerrifiedBug TerrifiedBug merged commit 9a4d7a5 into main Apr 27, 2026
13 checks passed
@TerrifiedBug TerrifiedBug deleted the chore/revert-demo-seed branch April 27, 2026 08:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant